1. Field of the Invention
The present invention relates to a controller for automatically stopping a motor. More particularly, it relates to a controller for automatically stopping a drive motor for a power window in a vehicle.
2. Description of the Related Art
A conventional apparatus for opening and closing a glass panel such as a window, in a vehicle employs a motor having a controller 30, as shown in FIG. 4. In raising the window a control switch (not shown) inside the vehicle is digitally operated (with a finger). As a result, a switch 31 of a relay in the controller 30 is coupled to a relay contact 32. A switch 43 is coupled to a relay contact 45.
A current from a power source, hereinafter referred to as "current source", flows through the relay contact 32, a motor 33, the relay contact 45 and a resistor R1, as indicated by 33, the relay contact 45 and a resistor R1, as indicated by solid line arrows in FIG. 4. Consequently, the motor 33 rotates in a predetermined direction in order to raise the window. At this time, a voltage across the resistor R1 is input to a comparator 34, where it is compared with a reference voltage LO of a first reference voltage circuit 35.
Since the reference voltage LO is set higher than the voltage across the resistor R1, the output voltage V.sub.out1 of the comparator 34 becomes an L (low) level. This L-level is output, via a resistor R2, to a comparator 36 where it is compared with a reference voltage HI of a second reference voltage circuit 37. Because the L-level output voltage V.sub.out1 is set lower than the reference voltage HI, the output of the comparator 36 becomes an H (high) level.
Consequently, the current source is supplied, via a diode 38 and a resistor R3, to the base of a transistor TR1, for turning the transistor TR1 on. This permits the power supply to energize a relay coil 39 of the relay, so that the switch 31 is held connected to the relay contact 32 by the electromagnetic force of the relay coil 39. Thus, even if the user removes his or her finger from the control switch, the motor 33 keeps rotating in the some direction.
When the window contacts the weather strip of the window frame, the load on the motor increases, and causes a lock current (overcurrent) to flow in the motor 33. The voltage across the resistor R1 increases accordingly. When this voltage becomes higher than the first reference voltage LO, the output voltage V.sub.out1 of the comparator 34 becomes an H level. A capacitor 41 is charged with this H-level output voltage V.sub.out1. When the charging of the capacitor 41 is complete, after about 0.7 second, the input voltage to the comparator 36 becomes higher than the reference voltage HI of the second reference voltage circuit 37. The output of the comparator 36 then becomes an L level, turns the transistor TR1 off, and causes the motor 33 to stop.
As described above, even when the window contacts the weather strip before it reaches the upper limit, causing the lock current to flow in the motor 33, the motor 33 does not stop immediately. The power supply to the motor is maintained for about 0.7 second after the increase in the load on the motor, so that the window can reach its upper limit.
On the other hand, with the switch 31 coupled to a relay contact 42, when the switch 43 is connected to a relay contact 44, the current flows in the direction opposite to the one in the above case. In this case, the motor 33 rotates in the direction to lower the window. Like in the previous case, the motor 33 stops running after about 0.7 second after the lock current flows in the motor 33, so that the window moves down to the lower limit.
Since the controller 30 includes many circuits, such as the reference voltage circuits 35 and 37, the comparators 34 and 36 and the transistor TR1, however, it has a complicated troublesome design, it is costly and the controller is relatively large in size.